package com.alisiwei.util;

import org.apache.log4j.Logger;

import com.alibaba.fastjson.JSON;

public class JsonUtil {
	private static Logger logger = Logger.getLogger(JsonUtil.class);
	
	/**
	 * 描述：将对象转为json
	 * 作者：zhangkai
	 * @param object
	 * @return
	 */
	public static String objectToJson(Object object){
		String result = "";
		result = JSON.toJSONString(object);
		logger.info("转化结果："+result);
		return result;
	}
}
